package com.meituan.sdk.model.ddzhkh.shangpin.productDealgroupOnline;

import com.meituan.sdk.annotations.ApiMeta;
import java.util.List;
import com.google.gson.reflect.TypeToken;
import javax.validation.constraints.NotBlank;
import java.lang.reflect.Type;
import com.meituan.sdk.internal.utils.JsonUtil;
import com.google.gson.annotations.SerializedName;
import javax.validation.constraints.NotNull;
import com.meituan.sdk.MeituanResponse;
import com.meituan.sdk.MeituanRequest;
import javax.validation.constraints.NotEmpty;

/**
* 上架团单
* This file was automatically generated.
*/
@ApiMeta(
    path = "/ddzhkh/shangpin/dealgroup/online",
    businessId = 59,
    apiVersion = "10091",
    apiName = "product_dealgroup_online",
    needAuth = true
)
public class ProductDealgroupOnlineRequest implements MeituanRequest<ProductDealgroupOnlineResponse> {
    /**
    * <p data-diff-id="ct-diff-id-4338a08c-25d2-4de7-865c-a996092cb61b"><span style="color: ">DealGroupDataDTO的json序列化后字符串形式</span></p>
    */
    @NotBlank(message = "data不能为空")
    @SerializedName("data")
    private String data;
    /**
    * <p data-diff-id="ct-diff-id-54aef63a-6d0a-46ca-a417-e033809a3781"><span style="color: ">来源，体检 : physical_examination</span></p>
    */
    @NotBlank(message = "source不能为空")
    @SerializedName("source")
    private String source;
    @NotEmpty(message = "opPoiIds不能为空")
    @SerializedName("opPoiIds")
    private List<String> opPoiIds;
    /**
    * <p data-diff-id="ct-diff-id-74793aef-9e22-4f1d-ab93-3abc3353559a">团单ID</p>
    */
    @NotNull(message = "dealGroupId不能为空")
    @SerializedName("dealGroupId")
    private Long dealGroupId;

    public String getData() {
        return data;
    }
    public void setData(String data) {
        this.data = data;
    }
    public String getSource() {
        return source;
    }
    public void setSource(String source) {
        this.source = source;
    }
    public List<String> getOpPoiIds() {
        return opPoiIds;
    }
    public void setOpPoiIds(List<String> opPoiIds) {
        this.opPoiIds = opPoiIds;
    }
    public Long getDealGroupId() {
        return dealGroupId;
    }
    public void setDealGroupId(Long dealGroupId) {
        this.dealGroupId = dealGroupId;
    }


    @Override
    public MeituanResponse<ProductDealgroupOnlineResponse> deserializeResponse(String response) {
        Type type = new TypeToken<MeituanResponse<ProductDealgroupOnlineResponse>>(){}.getType();
        return JsonUtil.fromJson(response, type);
    }
    @Override
    public String serializeToJson() {
        return JsonUtil.toJson(this);
    }


    @Override
    public String toString() {
        return "ProductDealgroupOnlineRequest{" + "data=" + data + "," + "source=" + source + "," + "opPoiIds=" + opPoiIds + "," + "dealGroupId=" + dealGroupId + "}";
    }
}
